Queues are used in a variety of applications, especially where resources are shared. For example, queues may be used to manage traffic in routers, file and data servers or to schedule processes and/or threads in single and/or multi-processor systems. A variety of techniques may be used to prioritize resource requests in an effort to improve throughput or efficiency or to guarantee a quality of service (QoS). However, many of these techniques run the risk of starving some requesters. In order to address the issue of starvation, complex algorithms may be used to enqueue and/or de-queue resource requests based on a variety of parameters. However, when complex algorithms are used to reduce starvation, precious system resources are consumed by the increased calculations and/or delays are introduced, thereby reducing overall throughput.
What is needed is a method and apparatus for enqueing and dequeuing requests that reduces starvation based on an economical use of system resources.